<?php

class Admin extends CI_Controller {

    function admin() {
        parent::__construct();
        $this->load->library('session');
        $this->load->model('mmaster');
        $this->load->helper('url');
        //$this->is_logged_in();
    }

    function is_logged_in() {
        $is_logged_in = $this->session->userdata('is_logged_in');
        if (!isset($is_logged_in) || $is_logged_in != true) {
            redirect(base_url() . 'index.php/login');
        }
    }

    function index() {
        $this->mmaster->setReleaseAllUsers();
        redirect(base_url() . 'index.php/main/welcome');
    }

}

?>